"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.default = void 0;

var _react = require("react");

/**
 * @see https://github.com/streamich/react-use/blob/master/docs/useLatest.md
 */
var useLatest = function useLatest(value) {
  var ref = (0, _react.useRef)(value);
  ref.current = value;
  return ref;
};

var _default = useLatest;
exports.default = _default;